Method and apparatus for displaying multi-task interface

ABSTRACT

An embodiment of the present invention provides a method for displaying a multi-task interface. The method includes: receiving, by a terminal, a request submitted by a user for displaying a multi-task interface; acquiring tasks started by the user and setting, according to the number of tasks started by the user and a start sequence, an arrangement manner of the multi-task interface; classifying the tasks started by the user into a video playing task and a non-video playing task; and separately drawing the video playing task and the non-video playing task according to the arrangement manner of the multi-task interface to obtain the multi-task interface, and displaying the multi-task interface to the user. In addition, embodiments of the present invention provide a corresponding terminal and a remote control.

CROSS-REFERENCE TO RELATED APPLICATION

This application claims priority to Chinese Patent Application No.201210257559.3, filed on Jul. 24, 2012, which is hereby incorporated byreference in its entirety.

TECHNICAL FIELD

The present invention relates to the field of communicationstechnologies, and in particular, to a method and an apparatus fordisplaying a multi-task interface.

BACKGROUND

As people raises increasingly-higher requirements for a terminal devicesuch as a mobile phone or a set-top box, a manner in which a terminaldevice manages a task has gradually changed from single-task running toa multi-task manner, and a system allows multiple tasks tosimultaneously work, so that a user's requirements such as surfing theInternet, listening to music, and chatting may be simultaneously met.When the user switches between multiple tasks, icons of tasks usedrecently may be displayed through a certain operation. Then an icon of atask to which the user wants to switch is selected to switch to the newtask.

In the prior art, a conventional multi-task interface of a mobile phone,a set-top box, or the like, presents icons of tasks that a user has runin a latest period of time or an icon of a currently running task.Information that may be conveyed to the user by using this manner isrelatively little, because an icon is only a representation of a taskand an interface when a task is running cannot be seen when only theicon of the task is displayed. Particularly, as nowadays various typesof terminal applications are increasingly abundant, a user installs oruninstalls a new application at an increasingly-higher frequency. Forsome newly installed applications, more often a user is not familiarwith an icon, feels very strange when seeing the icon, and does notunderstand which task the icon represents.

In addition, an icon on a multi-task interface of a terminal such as anexisting mobile phone or a set-top box is often static and an interfacewhen a task is running cannot be displayed. Taking a video playing taskas an example, on a conventional multi-task interface, a user can seeonly an icon of a task instead of abbreviated information about contentcurrently being played. In addition, the size of an icon on a multi-taskinterface is fixed and cannot be changed to a different size along witha change in the number of tasks, and therefore cannot either expresssome different information as the type of the task changes.

SUMMARY

To solve a technical issue that an existing multi-task interface canonly display a fixed task icon to convey limited information to a user,an embodiment of the present invention provides a method for displayinga multi-task interface. The method includes: receiving, by a terminal, arequest submitted by a user for displaying a multi-task interface;acquiring tasks started by the user and setting, according to the numberof tasks started by the user and a start sequence, an arrangement mannerof the multi-task interface; classifying the tasks started by the userinto a video playing task and a non-video playing task; and separatelydrawing the video playing task and the non-video playing task accordingto the arrangement manner of the multi-task interface to obtain themulti-task interface, and displaying the multi-task interface to theuser.

An embodiment of the present invention provides a terminal. The terminalincludes: a receiving module, configured to receive a request submittedby a user for displaying a multi-task interface; a setting module,configured to acquire tasks started by the user and set, according tothe number of tasks started by the user and a start sequence, anarrangement manner of the multi-task interface; a drawing module,configured to classify the tasks started by the user into a videoplaying task and a non-video playing task and separately draw, accordingto the arrangement manner of the multi-task interface that is set by thesetting module, the video playing task and the non-video playing task toobtain the multi-task interface; and a displaying module, configured todisplay the multi-task interface drawn by the drawing module to theuser.

Another embodiment of the present invention further provides a remotecontrol, configured to operate a set-top box, including the following:The remote control includes a multi-task interface function key; andafter receiving a key-pressing operation performed by a user on themulti-task interface function key, the remote control identifies thekey-pressing operation as a command for displaying a multi-taskinterface and sends a request for displaying the multi-task interface tothe set-top box.

By using the solutions for displaying a multi-task interface that aredisclosed in the embodiments, a multi-task interface displays no longersimple task icons. Instead, display interfaces, which are obtained aftera terminal separately draws a video playing task and a non-video playingtask according to an arrangement manner of the multi-task interface, arecapable of providing a user with more information to better distinguishvarious tasks from one another.

BRIEF DESCRIPTION OF DRAWINGS

FIG. 1 is a schematic diagram of a sequential relationship between agraphic layer and a video layer according to an embodiment of thepresent invention;

FIG. 2 is a schematic diagram of a method for displaying a multi-taskinterface according to an embodiment of the present invention;

FIG. 3 is a flowchart of steps for displaying a multi-task interfaceaccording to an embodiment of the present invention;

FIG. 4 is a schematic diagram of a remote control that has a “multi-taskinterface” function key according to an embodiment of the presentinvention;

FIG. 5 is an exemplary diagram of displaying a multi-task interfaceaccording to an embodiment of the present invention;

FIG. 6 is a flowchart of drawing a multi-task interface according to anembodiment of the present invention;

FIG. 7 is an exemplary diagram of a display interface of a music playingtask including an additional element according to an embodiment of thepresent invention;

FIG. 8 is an exemplary diagram of drawing irregular boundaries of amulti-task interface according to an embodiment of the presentinvention;

FIG. 9 is a schematic structural diagram of a terminal according to anembodiment of the present invention; and

FIG. 10 is a schematic diagram of the internal structure of a drawingmodule according to an embodiment of the present invention.

DESCRIPTION OF EMBODIMENTS

To facilitate persons of ordinary skill in the art to understand andimplement the present invention, the following describes embodiments ofthe present invention with reference to the accompanying drawings.

To solve the foregoing technical issue, an embodiment of the presentinvention provides a method for displaying a multi-task interface. Aterminal to which the method may be applied includes but is not limitedto a set-top box, a smart mobile phone, a tablet computer, and the like.

Generally, content displayed on the terminal may be classified into twotypes: graphic layer and video layer. For presented content of thegraphic layer, generally an SDK (Software Development Kit, softwaredevelopment kit) provides an API (Application Programming Interface,application programming interface) for a developer to perform control.Generally, presented content of the video layer is automaticallycompleted by a bottom layer of a decoding and presentation chip of theterminal. The developer cannot participate and perform control. The SDKprovides an API for the developer to set a sequential relationship (a Zsequence) between the graphic layer and the video layer. The sequentialrelationship between the graphic layer and the video layer is shown inFIG. 1, which indicates two cases: the graphic layer is in front or thevideo layer is in front.

The graphic layer may be composed of multiple sublayers. Taking aset-top box as an example, generally the graphic layer may include abrowser layer, a caption layer, a teletext (teletext) layer, and thelike. A relationship between various sublayers includes a Z sequence andtransparency. A Z sequence relationship between sublayers is the same asthe Z sequence relationship between the graphic layer and the videolayer as described previously as shown in FIG. 1; and the transparencyindicates whether a preceding sublayer completely shades content of asucceeding sublayer. For ease of description, a combined operation ofsetting the Z sequence and the transparency is subsequently called ablit operation. The graphic layer comes into being after a blitoperation is performed on the multiple graphic sublayers.

In the embodiment of the present invention, display of a multi-taskinterface is implemented by adding a multi-task interface layer to thegraphic layer. Certainly, this may also be implemented by reusing anexisting browser layer or caption layer.

FIG. 2 is a schematic diagram of a method for displaying a multi-taskinterface according to an embodiment of the present invention. Steps inthe method are described in detail as follows:

Step 201: A terminal receives a request submitted by a user fordisplaying a multi-task interface.

The terminal includes but is not limited to a mobile phone, a tabletcomputer, a set-top box, and the like.

Step 202: The terminal acquires tasks started by the user and sets,according to the number of tasks started by the user and a startsequence, an arrangement manner of the multi-task interface.

A task to be presented on the multi-task interface is a task that theuser has started and has not yet exited. The terminal sets anarrangement manner of various tasks on the multi-task interfaceaccording to the number of tasks started by the user and a sequence ofstart time.

Specific content about setting the arrangement manner of the multi-taskinterface is described in an embodiment to follow later.

Step 203: The terminal classifies the tasks started by the user into avideo playing task and a non-video playing task.

According to the content described previously, means by which theterminal processes a graphic layer and a video layer are different.Therefore, the tasks started by the user need to be classified into thevideo playing task and the non-video playing task for separateprocessing.

Step 204: Separately draw the video playing task and the non-videoplaying task according to the foregoing arrangement manner of themulti-task interface to obtain the multi-task interface, and display themulti-task interface to the user.

By using the solution for displaying a multi-task interface that isdisclosed in this embodiment, a multi-task interface displays no longersimple task icons. Instead, display interfaces, which are obtained aftera terminal separately draws a video playing task and a non-video playingtask according to an arrangement manner of the multi-task interface, arecapable of providing a user with more information to better distinguishvarious tasks from one another.

FIG. 3 is a flowchart of steps for displaying a multi-task interfaceaccording to an embodiment of the present invention. The followingdescribes in detail the steps for displaying a multi-task interface withreference to this diagram.

Step 301: A terminal starts a multi-task interface task according to auser's request.

In response to the user's request, the terminal starts a specific taskto process the user's request for displaying a multi-task interface. Forease of description, in the following, this task is called a “multi-taskinterface task”. The name should not be construed as a limitation toembodiments of the present invention.

Particularly, for a set-top box, the embodiment of the present inventionprovides a remote control that has a “multi-task interface” function keyas shown in FIG. 4. When a user presses a Home key shown in FIG. 4, itindicates requesting the set-top box to display a multi-task interface.The remote control mentioned in this embodiment includes but is notlimited to a conventional remote control, a soft remote control(auxiliary control software developed on Android or iOS), an air mouse,and the like.

While the terminal is starting the multi-task interface task, acurrently running task switches to a back end and a correspondingoperation is performed depending on whether the currently running taskis a music playing task: When the multi-task interface is entered from amusic playing task, the music playing task continues to run at the backend and music continues to be played; or when the user enters themulti-task interface from another task, the original running taskpauses.

After the multi-task interface task is started, execution subjects ofall the following steps are the multi-task interface task.

Step 302: Acquire tasks to be displayed on the multi-task interface.

Here, the acquired task to be displayed on the multi-task interface is atask that the user has started and has not yet exited and generallyincludes a corresponding task interface but excludes a back-end serviceautomatically started by a system, for example, an NTP (Network TimeProtocol, Network Time Protocol) time service will not be displayed onthe multi-task interface.

Step 303: Set an arrangement manner of the multi-task interface.

The multi-task interface task may set the arrangement manner of themulti-task interface according to the number of tasks currently runningand a sequence of task start time. The arrangement manner of themulti-task interface includes arranged positions and display sizes ofvarious tasks started by the user on the multi-task interface.

Particularly, in the embodiment of the present invention, the multi-taskinterface task may dynamically adjust the arrangement manner of themulti-task interface according to the number of tasks started by theuser.

FIG. 5 is an exemplary diagram of displaying a multi-task interfaceaccording to an embodiment of the present invention. Each digitrepresents a different task displayed on the multi-task interface. Thisdiagram shows that the multi-task interface takes on differentarrangement manners as the number of tasks is different. When the numberof tasks started by the user is large and all of them cannot bedisplayed on one page, the tasks may be displayed on multiple pages.

The above arrangement manners of the multi-task interface are examplesonly. For multi-task interfaces with different resolution andlength-to-width ratios, the number of displayable tasks in each row isalso different. This is still within the protection scope of theembodiment of the present invention.

Step 304: Determine types of the tasks started by the user.

The multi-task interface task acquires, by using an inter-processcommunication mechanism, the types of these tasks, which include but arenot limited to the following types: a video playing task, a music task,an image task, a browser task, and the like. A task type reflects a taskfor which an additional element needs to be displayed or a non-videoplaying task for which a task interface needs to be constantly updatedon the multi-task interface.

The foregoing task types may be summarized as two types: a video playingtask and a non-video playing task. A reason why to distinguish the twotypes of tasks is that different drawing methods need to be used fordifferent types of tasks in steps to follow later.

Step 305: Draw the multi-task interface.

The video playing task and the non-video playing task are separatelydrawn according to the foregoing arrangement manner of the multi-taskinterface to obtain the multi-task interface.

For a video playing task, its display interface is obtained by settingdisplay attributes of a decoder; and for a non-video playing task, itsdrawing includes drawing of a running interface of the task and itsadditional display element (in a case that the task has any additionaldisplay element). A detailed drawing process is described in anembodiment to follow later.

Step 306: Display the multi-task interface.

The multi-task interface may be displayed to the user after the drawingis completed.

Step 307: Perform a corresponding operation according to the user'schoice.

After the terminal displays the multi-task interface to the user, theuser may request, through the interface, the terminal to perform variousoperations. For example, on the interface, the user may select to switchto a certain task and may also select to exit a certain task.

Particularly, an embodiment of the present invention provides a methodfor switching a task, where the method is applied to a remote control.The method may be also applied to the remote control that has a“multi-task interface” function key provided in the foregoingembodiment. After the set-top box displays the multi-task interface tothe user through a television set, if a focal point of the remotecontrol stays on a certain task for a period of time (such as onesecond), the multi-task interface task will switch a currently runningtask to this certain task whereas the currently running task will switchto a status of running at the back end.

An example is given to describe a change in the running status of a taskwhen the focal point of the remote control moves: When the user selectsto enter the multi-task interface from a music playing task (a musicplayer A), the music player A may continue with playing and at thistime, no focal point is set on the multi-task interface. The user mayoperate the remote control to move the focal point. When the focal pointmoves to a video playing task and stays for a preset period of time(such as one second), the original music playing task (the music playerA) pauses, the video playing task starts to run on the multi-taskinterface, and a small window is used for video playing. Then the useroperates the remote control again to move the focal point from the videoplaying task to another browser task and stays for a preset period oftime (such as one second), the video playing task pauses and theoriginal music playing task (the music player A) resumes its running.When the focal point moves once again from the browser task to anothermusic playing task (a music player B) and stays for a preset period oftime (such as one second), the original music playing task (the musicplayer A) pauses and the new music playing task (the music player B)starts running Hoping that the music player B stops playing, the usermay move the focal point to an abbreviated interface of another task andlet the focal point stay for a certain time, so that the music player Aperforms playing. The rest may be deduced by analogy, making it possibleto smoothly switch between multiple tasks.

By using the solutions for displaying a multi-task interface that aredisclosed in the embodiment of the present invention, a dynamicinterface when a task runs may be displayed on a multi-task interface ofa terminal such as a smart mobile phone, a tablet computer, or a set-topbox, instead of simply displaying a task icon. In addition, moreinformation may be presented to a user by combining display of anadditional element. Furthermore, it is made possible that experiencewith music playing or another real-time service is not affected duringmulti-task interface browsing, and quick switching of played content maybe further made possible during switching between multiple music playingtasks.

After the multi-task interface drawing is completed, some non-videoplaying tasks may still be constantly updated when they are on themulti-task interface. For example, for a VideoPhone (video phone) taskor an album task that automatically plays, its picture may still beperiodically updated when the task is on the multi-task interface.

An embodiment of the present invention provides a method for updating amulti-task interface. Updating of a multi-task interface first needs torely on the types of the tasks that are acquired in the preceding step304. For a task that needs to be constantly updated, an updating periodof the task is acquired. Then a multi-task interface task periodicallydraws a new display interface according to the task updating period andkeeps updating the display interface of the task, so that presentationof a real-time service is not affected when the task is on themulti-task interface. For example, a video phone task displayed on themulti-task interface may still keep being updated.

FIG. 6 is a flowchart of drawing a multi-task interface according to anembodiment of the present invention. The following describes in detail aprocess of drawing a multi-task interface with reference to thisdiagram.

Step 601: A multi-task interface task first classifies, according totypes of tasks, tasks started by a user into two types: a video playingtask and non-video playing task.

As mentioned in the preceding embodiment, because for a task of a videotype, a running interface thereof cannot be acquired by using by usingan inter-process communication mechanism and a running interface of avideo playing task is updated very quickly, a video playing task needsto be separately processed.

Step 602: Place the video playing task at a specified position of amulti-task interface by directly invoking an API and set its displaysize.

For a video playing task, a decoder directly performs drawing. Themulti-task interface task sets, according to a position and a size ofthe video playing task that are determined in the step 305, a displayattribute of the decoder by invoking the API, so that the video playingtask can perform playing at the corresponding position on the multi-taskinterface according to the set size. In addition, pause and resumptionof the video playing task may be controlled according to an operation ofthe user.

Step 603: For the non-video playing task, the multi-task interface taskacquires running interfaces of the tasks in turn and zooms in or out therunning interface according to the size set in the preceding step 303.

For non-video playing tasks started by the user, respective runninginterfaces are provided according to invoking commands from themulti-task interface task.

The running interfaces provided by various tasks may be current runninginterfaces or may also be running interfaces with customized settings,so that these tasks have an individualized and nice-looking effect ofdisplay on the multi-task interface. The running interfaces withcustomized settings may be stored in the tasks in advance. After thecommands for invoking the running interfaces are received, thecustomized running interfaces are sent to the multi-task interface task.

After the running interfaces of the tasks are acquired, the runninginterfaces are zoomed in or out according to the size set in the step303 to obtain zoomed running interfaces of the tasks.

Step 604: Determine whether any additional element needs to be presentedfor the non-video playing task.

In the preceding step 304, the multi-task interface task has acquiredthe types of the tasks by using the inter-process communicationmechanism, including tasks for which additional elements need to bepresented. In this step, the multi-task interface task determines,according to such information, a non-video playing task for whichadditional elements need to be presented.

Step 605: For the non-video playing task for which additional elementsneed to be presented, acquire additional display elements of the tasksand perform a blit operation on these additional display elements andthe running interfaces of the tasks that are acquired in the step 603 toobtain display interfaces of the tasks.

For example, FIG. 7 shows a display interface of a music playing taskincluding an additional element. In addition to a running interface thatincludes the task itself, a task icon is combined at the lower rightcorner of the running interface to avoid the following issue: Whenmultiple players are playing same music, their running interfaces areconsistent and can hardly be distinguished. In addition, the name ofmusic currently being played is further presented as an additionalelement at the bottom of the running interface of the task.

With reference to the display interface of the music playing taskincluding the additional element as shown in FIG. 7, an embodiment ofthe present invention discloses a method for drawing irregularboundaries of a multi-task interface.

By using this drawing method, boundaries of display interfaces of eachtask may be defined as two rectangular boxes, which are called an innerinterface and an outer interface. As shown in FIG. 8, taking amulti-task interface that includes four tasks as an example, zoomedrunning interfaces of the tasks are drawn on the inner interfaces, andsizes and gaps of the inner interfaces of the tasks are kept the same onthe multi-task interface. “Setting an arrangement manner of the taskinterface” as described in the preceding step 303 is setting the sizesand gaps of the inner interfaces of various tasks, where the sizes andgaps of the inner interfaces of various tasks are determined accordingto the number of currently running tasks. The zoomed running interfacesof the tasks that are obtained in the preceding step 603 constitute theinner interfaces.

Larger than an inner interface, an outer interface is used to drawadditional display elements of a task, such as the music task icon andinformation about the name of music currently being played as mentionedin a preceding example. As shown in FIG. 7, a scope of the runninginterface of a music playing task belongs to a scope of an innerinterface, and the music name and the task icon belong to a scope of anouter interface. For a task that does not have any additional displayelement, an outer interface does not need to be drawn or only a blankouter interface may be drawn.

Step 606: Set display positions of the display interfaces obtained inthe preceding step.

The display positions are set according to the arrangement manner of thetask interface that is set in the preceding step 303.

Step 607: For the non-video playing task for which no additional elementneeds to be presented, no additional element needs to be acquired andtherefore no blit operation needs to be performed. The abbreviatedrunning interfaces of the tasks that are obtained in the step 603 aredisplay interfaces of such tasks. The display positions of such tasksare directly set.

The multi-task interface is obtained after the preceding steps 601 to607 are executed.

With reference to the content disclosed in the preceding embodiment, inan embodiment of the present invention, drawing of a non-video playingtask may be classified into two types: drawing of a non-video playingtask with an outer interface and drawing of a non-video playing taskwithout an outer interface.

The drawing of a non-video playing task without an outer interface meansthat, for a task without any additional display element, only its innerinterface is drawn and the inner interface constitutes a displayinterface of the task. The drawing of a non-video playing task with anouter interface includes two cases: in one case, for a non-video playingtask with an additional display element, the additional display elementconstitutes the outer interface; and in the other case, for a non-videoplaying task without any additional display element, a blank outerinterface is drawn.

The drawing of a non-video playing task without an outer interfaceincludes the following steps:

A. Acquire a running interface of the non-video playing task;

B. Zoom in or out the running interface of the non-video playing taskaccording to a display size of the non-video playing task on themulti-task interface to obtain a display interface of the non-videoplaying task; and

C. Set a display position of the display interface on the multi-taskinterface according to an arranged position of the non-video playingtask on the multi-task interface.

The drawing of a non-video playing task with an outer interface includesthe following steps:

A. Acquire a running interface of the non-video playing task;

B. Zoom in or out the running interface of the non-video playing taskaccording to a display size of the non-video playing task on themulti-task interface to obtain an inner interface of the non-videoplaying task;

C. Draw an outer interface of the non-video playing task; where:

the drawing an outer interface specifically includes the followingsteps:

C1: Determine whether any additional element needs to be presented forthe non-video playing task;

C2. Draw a blank outer interface if no additional element needs to bepresented for the non-video playing task;

C3. Acquire additional display elements of the non-video playing task ifthe additional elements need to be presented for the non-video playingtask; and

C4. Set a sequential relationship and a transparency relationshipbetween the additional display elements to obtain the outer interface ofthe non-video playing task.

D. Set a sequential relationship and a transparency relationship betweenthe inner interface and the outer interface of the non-video playingtask to obtain a display interface of the non-video playing task; and

E. Set a display position of the display interface on the multi-taskinterface according to an arranged position of the non-video playingtask on the multi-task interface.

It should be noted that, in the embodiment of the present invention,sizes and gaps of inner interfaces of various tasks are kept the same;while for the outer interfaces, because some tasks do not have anyadditional display element, probably they do not have any outerinterface or have only one blank outer interface, gaps of outerinterfaces of various tasks are not the same, and the outer interfacesof various tasks may overlap or cover one another on a precondition ofensuring that the additional elements of the tasks are not shaded. Thenvarious multi-task interfaces with varied appearance and proper layoutmay be obtained from combination through the foregoing operations.

With reference to foregoing embodiments, this embodiment discloses aterminal, configured to implement the solutions for displaying amulti-task interface that are disclosed in the foregoing embodiments ofthe present invention. FIG. 9 is a schematic structural diagram of aterminal according to an embodiment of the present invention. Theterminal includes but is not limited to a mobile phone, a set-top box, atablet computer, and the like. The following describes in detail variousmodules of the terminal. The terminal includes:

a receiving module 901, configured to receive a request submitted by auser for displaying a multi-task interface;

a setting module 902, configured to acquire tasks started by the userand set, according to the number of tasks started by the user and astart sequence, an arrangement manner of the multi-task interface;where:

a task to be displayed on the multi-task interface is a task that theuser has started and has not yet exited and generally includes acorresponding task interface but excludes a back-end serviceautomatically started by a system, for example, an NTP (Network TimeProtocol, Network Time Protocol) time service will not be displayed onthe multi-task interface; and

the setting, by the setting module 902, an arrangement manner of themulti-task interface specifically includes setting arranged positionsand sizes of the tasks started by the user on the multi-task interface;

a drawing module 903, configured to classify the tasks started by theuser and acquired by the setting module 902 into a video playing taskand a non-video playing task, and separately draw, according to thearrangement manner of the multi-task interface that is set by thesetting module 902, the video playing task and the non-video playingtask to obtain the multi-task interface; where:

a reason why to classify the tasks started by the user into the videoplaying task and the non-video playing task and separately draw them hasbeen described in detail in the preceding embodiment and not re-statedherein; and

a displaying module 904, configured to display the multi-task interfacedrawn by the drawing module 903 to the user.

As shown in FIG. 9, a terminal provided in an embodiment of the presentinvention further includes a switching module 905, configured to switch,after the receiving module 901 receives the request submitted by theuser for displaying a multi-task interface, a currently running task onthe terminal to a back end and determine whether the task is a musicplaying task; and continue to run the task if the task is a musicplaying task, or pause the task if the task is not a music playing task.

After receiving the request submitted by the user for displaying amulti-task interface, the terminal needs to switch the currently runningtask to the back end and perform a different operation according to atype of the task. Particularly, in this embodiment, if the currentlyrunning task is a music playing task, the running of the task continues;or if the currently running task is not a music playing task, therunning of the task is paused.

After the displaying module 904 displays the drawn multi-task interfaceto the user, running interfaces of tasks displayed on the multi-taskinterface, such as a video phone task and an electronic album task, mayfurther be periodically updated. Therefore, a terminal provided inanother embodiment of the present invention further includes an updatingmodule 906, configured to periodically update the multi-task interfaceafter the displaying module 904 displays the multi-task interface to theuser.

The drawing module 903 separately draws the video playing task and thenon-video playing task. Corresponding to this, as shown in FIG. 10, inan embodiment of the present invention, the module is divided into asubmodule 931 for drawing a video playing task and a submodule 932 for adrawing non-video playing task, respectively configured to draw thevideo playing task and the non-video playing task.

The submodule 931 for drawing a video playing task is configured to seta display attribute of a decoder according to an arranged position and adisplay size of the video playing task on the multi-task interface.

The submodule 931 for drawing a video playing task sets the displayattribute of the decoder by directly invoking an API, so that the videoplaying task can be displayed at a corresponding position according tothe set size on the multi-task interface.

The drawing, by the submodule 932 for drawing a non-video playing task,a non-video playing task is specifically:

acquiring a running interface of the non-video playing task; zooming inor out the running interface of the non-video playing task according toa display size of the non-video playing task on the multi-task interfaceto obtain a display interface of the non-video playing task; and settinga display position of the display interface on the multi-task interfaceaccording to an arranged position of the non-video playing task on themulti-task interface.

Alternatively, the drawing, by the submodule 932 for drawing a non-videoplaying task, a non-video playing task is specifically:

acquiring a running interface of the non-video playing task; zooming inor out the running interface of the non-video playing task according toa display size of the non-video playing task on the multi-task interfaceto obtain an inner interface of the non-video playing task; drawing anouter interface of the non-video playing task; setting a sequentialrelationship and a transparency relationship between the inner interfaceand the outer interface of the non-video playing task to obtain adisplay interface of the non-video playing task; and setting a displayposition of the display interface on the multi-task interface accordingto an arranged position of the non-video playing task on the multi-taskinterface.

By using the terminal disclosed in the embodiment of the presentinvention, after a request submitted by a user for displaying amulti-task interface is received, a video playing task and a non-videoplaying task are separately drawn when a multi-task interface to obtaindisplay interfaces of the tasks is drawn instead of simply displayingicons of the tasks. In this way, running interfaces of the tasks aredisplayed and, compared with the icons of the tasks, are capable ofconveying more information to the user. This better helps to distinguishvarious tasks from one another. In addition, an updating mechanism isadded during display of the multi-task interface and is capable ofupdating a display interface of a task in real time.

An embodiment of the present invention provides a remote control foroperating a set-top box. As shown in FIG. 4, the remote control for aset-top box includes a multi-task interface function key. A user sends arequest for displaying a multi-task interface to the set-top box bypressing this key.

After receiving a key-pressing operation performed by the user on themulti-task interface function key, the remote control identifies thekey-pressing operation as a command for displaying a multi-taskinterface and sends a request for displaying the multi-task interface tothe set-top box. After performing the operations for displaying themulti-task interface that are disclosed in the preceding embodiment, theset-top box displays the multi-task interface through a television setto the user.

The remote control mentioned in this embodiment includes but is notlimited to a conventional remote control, a soft remote control(auxiliary control software developed on Android or iOS), an air mouse,and the like. Using the remote control provided in the embodiment of thepresent invention solves a defect that an existing remote control doesnot have a multi-task interface function key, and a user may send arequest for displaying a multi-task interface by performing an operationof pressing this key, thereby greatly improving user experience.

Persons of ordinary skill in the art may be aware that, in combinationwith the methods described in the embodiments disclosed in thisspecification, the steps and units may be implemented by electronichardware, computer software, or a combination thereof. To clearlydescribe the interchangeability between the hardware and the software,the foregoing has generally described compositions and steps of everyembodiment according to functions. Whether the functions are performedby hardware or software depends on particular applications and designconstraint conditions of the technical solutions. Persons skilled in theart may use different methods to implement the described functions foreach particular application, but it should not be considered that theimplementation goes beyond the scope of the present invention.

The steps of the methods described by combining the embodimentsdisclosed in this specification may be implemented by hardware, asoftware program executed by a processor, or a combination thereof. Thesoftware program may be placed in a random access memory (RAM), amemory, a read-only memory (ROM), an electrically programmable ROM, anelectrically erasable programmable ROM, a register, a hard disk, amovable disk, a CD-ROM, or a storage medium in any other form publiclyknown in the technical field. The software or program includes thefollowing steps: (method claims).

Although some embodiments of the present invention have been shown anddescribed, persons of ordinary skill in the art should understand thatthey may make various modifications to these embodiments withoutdeparting from the principle and spirit of the present invention andsuch modifications should fall within the scope of the presentinvention.

What is claimed is:
 1. A method for displaying a multi-task interface,comprising: receiving, by a terminal, a request for displaying amulti-task interface; acquiring tasks started and setting, according tothe number of tasks started and a start sequence, an arrangement mannerof the multi-task interface, wherein the arrangement manner of themulti-task interface comprises arranged positions and display sizes ofthe tasks started on the multi-task interface; classifying the tasksstarted into a video playing task and a non-video playing task; anddrawing the video playing task and the non-video playing tasksseparately according to the arrangement manner of the multi-taskinterface to obtain the multi-task interface, and displaying themulti-task interface, wherein the drawing the non-video playing taskaccording to the arrangement manner of the multi-task interfacecomprises: acquiring a running interface of the non-video playing task;zooming in or out the running interface of the non-video playing taskaccording to a display size of the non-video playing task on themulti-task interface to obtain the display interface of the non-videoplaying task; and setting a display position of the display interface onthe multi-task interface according to an arranged position of thenon-video playing task on the multi-task interface.
 2. The methodaccording to claim 1, after the displaying the multi-task interface,further comprising: updating a display interface of the non-videoplaying task on the multi-task interface.
 3. The method according toclaim 2, wherein the updating the display interface of the non-videoplaying task on the multi-task interface comprises: acquiring anupdating period of the non-video playing task; and periodicallyre-drawing the non-video playing task according to the updating periodto obtain the updated display interface of the non-video playing task onthe multi-task interface.
 4. The method according to claim 1, whereinthe drawing the video playing task according to the arrangement mannerof the multi-task interface comprises: setting a display attribute of adecoder of the video playing task according to an arranged position anda display size of the video playing task on the multi-task interface. 5.The method according to claim 1, wherein the receiving, by the terminal,the request for displaying a multi-task interface comprises: receiving,by a set-top box, the request through a remote control for displaying amulti-task interface.
 6. The method according to claim 5, after thedisplaying the multi-task interface to the user, further comprising:monitoring, by the set-top box, a duration in which a focal point of theremote control stays on the multi-task interface, and if the durationreaches a preset value, switching the currently running task to a taskon which the focal point of the remote control stays.
 7. A method fordisplaying a multi-task interface, comprising: receiving, by a terminal,a request for displaying a multi-task interface; acquiring tasks startedand setting, according to the number of tasks started and a startsequence, an arrangement manner of the multi-task interface, wherein thearrangement manner of the multi-task interface comprises arrangedpositions and display sizes of the tasks started on the multi-taskinterface; classifying the tasks started into a video playing task and anon-video playing task; and drawing the video playing task and thenon-video playing task separately according to the arrangement manner ofthe multi-task interface to obtain the multi-task interface, anddisplaying the multi-task interface, wherein the drawing the non-videoplaying task according to the arrangement manner of the multi-taskinterface comprises: acquiring a running interface of the non-videoplaying task; zooming in or out the running interface of the non-videoplaying task according to a display size of the non-video playing taskon the multi-task interface to obtain an inner interface of thenon-video playing task; drawing an outer interface of the non-videoplaying task; setting a sequential relationship and transparencyrelationship between the inner interface and the outer interface of thenon-video playing task to obtain the display interface of the non-videoplaying task; and setting a display position of the display interface onthe multi-task interface according to an arranged position of thenon-video playing task on the multi-task interface.
 8. The methodaccording to claim 7, wherein the drawing the outer interface of thenon-video playing task comprises: determining whether any additionalelement should be presented for the non-video playing task; and drawinga blank outer interface if no additional element should be presented forthe non-video playing task, or acquiring additional display elements ofthe non-video playing task if the additional elements should bepresented for the non-video playing task; and setting a sequentialrelationship and transparency relationship between the additionaldisplay elements to obtain the outer interface of the non-video playingtask.